/**
 * 用户登录
 * @param params
 * @returns {AxiosPromise | *}
 * @author 千锋健哥
 */
const loginApi = (params) => {
    return $axios({
        url: managerGateway + '/user/auth/doLogin',
        method: 'post',
        data: {...params}
    })
};

/**
 * 退出方法
 * @param params
 * @author 千锋健哥
 */
function logout() {
    localStorage.removeItem('userInfo');
    window.top.location.href = '/backend/page/login/login.html';
    return;
}

/**
 * 获取菜单
 * @author 千锋健哥
 */
function findMenu() {
    return $axios({
        url: managerGateway + '/user/menu/all',
        method: 'post'
    })
}
